# 列表遍历  while循环 下标
list1 = ['python', 'java', 'javascript', 'golang', 'c++']
#          0          1        2            3        4
# print(list1[0])
# print(list1[1])
# print(list1[2])

'''
# 循环次数, 静态的数字
i = 0
while i < 6:
    print(list1[i])
    i += 1
'''
# 获取列表的长度
# print(len(list1))
i = 0
while i < len(list1):  # 5
    print(list1[i])
    i += 1
